# RUN: not tfg-translate -graphdef-to-mlir %s 2>&1 | FileCheck %s

# CHECK: INVALID_ARGUMENT: Duplicated node (or function argument) with the same name: `x`
# CHECK-NEXT: when importing function DuplicatedName

library {
  function {
    signature {
      name: "DuplicatedName"
      input_arg {
        name: "x"
        type_attr: "T"
      }
      output_arg {
        name: "y"
        type_attr: "T"
      }
      attr {
        name: "T"
        type: "type"
        allowed_values {
          list {
            type: DT_FLOAT
            type: DT_DOUBLE
            type: DT_INT32
            type: DT_INT64
          }
        }
      }
    }
    node_def {
      name: "x"
      op: "Identity"
      input: "x"
      attr {
        key: "T"
        value {
          placeholder: "T"
        }
      }
    }
    ret {
      key: "y"
      value: "x"
    }
  }
}
versions {
  producer: 762
}
